package cn.xopencode.userservice.enums;

import cn.xopencode.common.framework.core.IntArrayValuable;

import java.util.Arrays;

/**
 * 健康状况
 */
public enum HealthEnum implements IntArrayValuable {

    HEALTH0(0, "未知"),
    HEALTH1(1, "良好"),
    HEALTH2(2, "疾病");

    public static final int[] ARRAYS = Arrays.stream(values()).mapToInt(HealthEnum::getHealth).toArray();

    /**
     * 性别标识
     */
    private final Integer health;
    /**
     * 描述
     */
    private final String name;

    HealthEnum(Integer health, String name) {
        this.health = health;
        this.name = name;
    }

    public Integer getHealth() {
        return health;
    }

    public String getName() {
        return name;
    }

    @Override
    public int[] array() {
        return ARRAYS;
    }

}
